import { Inject, Injectable } from '@nestjs/common';
import * as Minio from 'minio';

@Injectable()
export class CommonService {
  @Inject('MINIO_CLIENT')
  private minioClient: Minio.Client;
  async upload(name: string) {
    return this.minioClient.presignedPutObject('dev', name, 3600);
  }
}
